<%@tag language="java" pageEncoding="UTF-8"%>
<%@tag import="fr.inserm.u915.organifooyi.model.OrganiFooyiDao"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="u" tagdir="/WEB-INF/tags" %>
<%@attribute name="aliquots" required="true" rtexprvalue="true" type="java.util.Collection" %>

<form method="POST" action="/organifooyi/db/aliquot/batch-update">

<table class="entityList">
	<thead>
		<tr>
			<th>Label</th>
			<th>Volume</th>
			<th>Concentration</th>
			<th>Creator</th>
			<th>Creation</th>
		</tr>
	</thead>
	<tbody>
		<c:forEach var="aliquot" items="${aliquots}">
			<tr>
				<td>
					<c:if test="${userHasWritePrivileges }">
						<input type="checkbox" name="aliquot_id" value="${aliquot.id}"/>
					</c:if>
					<u:aliquot-href u:aliquot="${aliquot}"/>
				</td>
				<td>
					${aliquot.volume}
				</td>
				<td>
					${aliquot.concNanoDrop}
				</td>
				<td>
					<u:user-href user="${aliquot.createdBy}"/>
				</td>
				<td>
					<c:out value="${aliquot.creation}" escapeXml="true"/>
				</td>
			</tr>
		</c:forEach>
	</tbody>
	<c:if test="${userHasWritePrivileges }">
	<tfoot>
	<input type="submit" value="Update Aliquot(s)" />
	</tfoot>
	</c:if>
</table>
</form>